package np13.sddb.queries;

import java.util.List;
import java.util.Map;

import np13.Slime;
import np13.Smell;
import np13.sddb.Result;
import np13.sddb.SDDB;

/**
 * Represents a query which can be passed to the {@link SDDB}.
 */
public interface Query {

	/**
	 * Applies the query to the actual database. May only be called from the
	 * {@link SDDB}. If the returned {@link Result} is not {@code null}, it will
	 * be placed on the display.
	 * 
	 * @param db
	 *            The actual database.
	 * @return The result (can be null).
	 */
	public Result applyToDB(Map<Slime, List<Smell>> db);

}
